<?php
	if ( ! defined('BASEPATH')) exit('No direct script access allowed');
	class Msite extends CI_Model
	{
		function __construct()
		{
			//parent::CI_Model();	
		}
		function edit_site()
		{		

			$this->load->helper('file');
			$data ="<?php
if ( ! defined('BASEPATH')) exit('No direct script access allowed'); 
\$config['sitename'] ='".$this->input->post('sitename')."';	
\$config['check_avatar'] =".$this->input->post('check_avatar').";
\$config['invite_limits'] =".$this->input->post('invite_limits').";
\$config['invite_points'] =".$this->input->post('invite_points').";
\$config['invite_coins'] =".$this->input->post('invite_coins').";
\$config['follow_validity'] =".$this->input->post('follow_validity').";
\$config['rt_validity'] =".$this->input->post('rt_validity').";
\$config['follow_limits_per_hour'] =".$this->input->post('follow_limits_per_hour').";
\$config['follow_limits_per_day'] =".$this->input->post('follow_limits_per_day').";
\$config['rt_limits_per_hour'] =".$this->input->post('rt_limits_per_hour').";
\$config['rt_limits_per_day'] =".$this->input->post('rt_limits_per_day')."; 
\$config['signin_points'] =".$this->input->post('signin_points').";
\$config['signin_coins'] =".$this->input->post('signin_coins').";
\$config['share_points'] =".$this->input->post('share_points')."; 
\$config['share_coins'] =".$this->input->post('share_coins').";
\$config['follow_points'] =".$this->input->post('follow_points').";
\$config['follow_coins'] =".$this->input->post('follow_coins').";
\$config['rt_points'] =".$this->input->post('rt_points').";
\$config['rt_coins'] =".$this->input->post('rt_coins').";            
\$config['followersCount_login_limits'] =".$this->input->post('followersCount_login_limits').";
\$config['give_points_limits'] =".$this->input->post('give_points_limits').";
\$config['reg_give_points'] =".$this->input->post('reg_give_points').";
\$config['rt_limits_coins_day'] =".$this->input->post('rt_limits_coins_day').";
\$config['description'] ='".$this->input->post('description')."';
\$config['client_id'] ='".$this->input->post('client_id')."';
\$config['client_secret'] ='".$this->input->post('client_secret')."';
\$config['refresh_token'] ='".$this->input->post('refresh_token')."';
?>";
				write_file('e:/host/hufen1/web/tt_app/config/siteset.php', $data);
				return true;	
			}
		
		
		
	}